package com.source.lightfowl.syslog.pojo;

import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import java.util.Date;

/**
 * @Author: 谢春泳
 * @Description:
 * @Date: 2020/2/25 21:48
 */
@Data
@Entity
public class Operation {

    @Id
    private String id;
    private String userId ; // 操作人账号
    private String clientIp ; // 客户端ip
    private String userName ; // 操作人姓名
    private String operUrl ; // 操作的url
    private String operEvent; //操作事件 增删改查
    private int   operType ; // 日志类型
    private String details;//访问细节

    private String reqType ; // 请求方式：POST或者GET
    private Date operTime ; // 操作时间

    @Override
    public String toString() {
        return "Operation{" +
                "id='" + id + '\'' +
                ", userId='" + userId + '\'' +
                ", clientIp='" + clientIp + '\'' +
                ", userName='" + userName + '\'' +
                ", operUrl='" + operUrl + '\'' +
                ", operEvent='" + operEvent + '\'' +
                ", operType=" + operType +
                ", details='" + details + '\'' +
                ", reqType='" + reqType + '\'' +
                ", operTime=" + operTime +
                '}';
    }
}
